package org.blankie.model;

import org.blankie.lang.Validate;

class ValidateListener implements DriverOperationListener {
    
    private final BlkAbstractDriver driver;
    
    ValidateListener(BlkAbstractDriver driver) {
        assert driver != null;
        this.driver = driver;
    }

    @Override
    public void operationStarted(OperationType type, BlkResource<? extends BlkPath> object) {
        Validate.equals("object.manager", object, driver);
    }

    @Override
    public void operationTerminated(OperationType type, BlkResource<? extends BlkPath> object, Object result) {
        return;
    }

}
